#!/bin/bash
IMAGENAME="peter/result"
VERSION="1.0.2"


docker kill $(docker ps | grep "result" | awk '{print $1}')
docker rmi $(docker images | grep "result" | awk '{print $3}')

#构建

#前端镜像
docker build -t ${IMAGENAME}:${VERSION} -f ./docker/huaxresult.Dockerfile .
docker tag ${IMAGENAME}:${VERSION} ${IMAGENAME}:latest


#运行
docker run -d -p 3010:80 -v /home/help4/huaxrobotdir:/huaxrobotdir --rm ${IMAGENAME}:${VERSION} 

